import 'package:flutter_demo/ui/pages/status/data/share_data.dart';

class ShareDataProxy {
  ShareData shareData;
  ShareDataProxy(this.shareData);
  // 规定对象相等的规则，如下userName属性值一样则认为两个对象相等
  @override
  bool operator ==(Object o) {
    if (identical(this, o)) return true;
    return o is ShareDataProxy && o.shareData == shareData;
  }

  String get tab {
    return "我是:${shareData.nickname}";
  }

  void changeName(String name) {
    shareData.setNickname(name);
  }
}
